package com.jialiang.exDemo01;

import com.jialiang.exDemo01.ex.ServiceException;
import com.jialiang.exDemo01.web.JsonResult;
import com.jialiang.exDemo01.web.ServiceCode;

public class Demo01Test {
    public static void main(String[] args) {
        // 成功
        JsonResult.ok(new Object());
        JsonResult.ok();

        // enum.code + message
        throw new ServiceException(ServiceCode.ERROR_BAD_REQUEST,"参数为空");

    }
}
